989d10b8361830f50123d4bc986bc26eb008daea,src/wyc/builder/FlowTypeChecker.java,FlowTypeChecker,expandAsEffectiveArray,#Expr#Context#,3511

Before Change



	public Nominal.Array expandAsEffectiveArray(Expr src, Context context)
			throws IOException, ResolveError {
		Nominal lhs = src.result();
		Type raw = lhs.raw();
		if (raw instanceof Type.EffectiveArray) {
			Type nominal = expandOneLevel(lhs.nominal());
			if (!(nominal instanceof Type.EffectiveArray)) {

After Change


	// =========================================================================

	public Nominal.Array expandAsEffectiveArray(Expr src, Context context) throws IOException, ResolveError {
		Type.EffectiveArray type = typeSystem.expandAsEffectiveArray(src.result().nominal());
		if (type == null) {
			syntaxError(errorMessage(INVALID_ARRAY_EXPRESSION), context, src);
		}